const { defineConfig } = require('@vue/cli-service')
const path = require('path')

function resolve(dir) {
  return path.join(__dirname, dir)
}

module.exports = defineConfig({
  transpileDependencies: true,
  configureWebpack: {
    resolve: {
      alias: {
        '@': resolve('src'),
      },
    },
  },
  devServer: {
    client: {
      overlay: false
    },
    proxy: {
      "/api": {
        target: "http://admin.xmall.com",
        changeOrigin: true,
        ws: true,
        secure: true,
      }
    }
  }
})
